package mis510.homefinders;

import mis510.homefinders.Map.JavaScriptInterface;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.webkit.WebChromeClient;
import android.webkit.WebSettings;
import android.webkit.WebView;
import android.widget.Button;

public class Reqform extends Activity{
	private static String useremail_new = null;
	Button bk_btn;
	Intent nextActivity;
	public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.reqform);
        System.out.println("reqform");
        
        Intent intent = this.getParent().getIntent();
		Bundle bundle = intent.getExtras();
		useremail_new = bundle.getString("useremail");
		System.out.println("user email req: "+useremail_new);
		
		bk_btn = (Button)findViewById(R.id.bk_btn);
		   bk_btn.setOnClickListener(new View.OnClickListener() {
	            @Override
	            public void onClick(View view) {
	            	nextActivity = new Intent(Reqform.this, SearchProperty.class);
	            	startActivity(nextActivity);
	            }
	        });
        
        WebView myWebView = (WebView) findViewById(R.id.reqform);
        myWebView.getSettings().setLoadWithOverviewMode(true);
        myWebView.getSettings().setUseWideViewPort(true);
        WebSettings webSettings = myWebView.getSettings();
        webSettings.setJavaScriptEnabled(true);
        webSettings.setBuiltInZoomControls(false);
        myWebView.setWebChromeClient(new WebChromeClient());
        myWebView.loadUrl("http://54.214.11.178:8080/HomeFinders/roommate/index.html");
        
        
	}

}
